package 蓝桥第二期2024;

public class 异或 {
    public static void main(String[] args) {
        int n = 2024;
        int count = 0;
        for (int i = 1; i <= n; i++) {
            int ans = i ^ n;
            System.out.print(ans + ",");
            if (ans < 2024) {
                count++;
            }
        }
        System.out.println();
        System.out.println(count);
    }
}
